<?php
//删除信息
error_reporting(E_ALL^E_WARNING);//隐藏除warning以为的错误警告
//连接数据库
$conn = mysqli_connect
('127.0.0.1','root','colourdragon','studentt');
//设置字符集
mysqli_query($conn,"set names utf8");




//用get得到要删除的学生id
$student_id = $_GET['id'];
//创建sql删除语句
$sql = "delete from `user` where id=$student_id";
//执行上面的sql语句
$ret = mysqli_query($conn,$sql);
if($ret){
    echo "删除成功！<a href='./index.php'>返回首页</a>";
}else{
    echo "修改失败！";
}